package com.gzhryc.shared_device.base.enums;

public enum ECouponType {

    DISCOUNT_COUPON(1, "折扣券")
    , VOUCHERS(2, "代金券")
    , COUPON_DAY(3, "免租期劵");

    private final Integer index;
    private final String note;

    ECouponType(Integer index, String note) {
        this.index = index;
        this.note = note;
    }

    public Integer index() {
        return index;
    }

    public String note() {
        return note;
    }

    public static String note(Integer index) {
        ECouponType[] temp = ECouponType.values();
        for (ECouponType item : temp) {
            if (item.index.equals(index)) {
                return item.note;
            }
        }
        return null;
    }
}
